<template>
    <div class="main_con">
        <div class="table_aera">
            <el-table  :data="tableData" :height="400"  :header-cell-style="{background:'#eef1f6'}">
                <el-table-column prop="" label="发票号码" min-width="120">
                    <template slot-scope="scope" >
                        <el-input size="small"></el-input>
                    </template>
                </el-table-column>
                <el-table-column prop="" label="开票日期" min-width="120">
                    <template slot-scope="scope" >
                        <el-date-picker
                            style="width:100%"
                            type="date"
                            size="small"
                            placeholder="选择日期">
                        </el-date-picker>
                    </template>
                </el-table-column>
                <el-table-column prop="" label="价税合计" min-width="120">
                    <template slot-scope="scope" >
                        <el-input-number size="small" controls-position="right"  :min="0" :max="100"></el-input-number>
                    </template>
                </el-table-column>
                <el-table-column prop="" label="发票金额" >

                </el-table-column>
                <el-table-column prop="" label="发票税额" >

                </el-table-column>
                <el-table-column prop="" label="备注" min-width="120">
                    <el-input size="small"></el-input>
                </el-table-column>
                <el-table-column prop="" label="附件" min-width="100">
                    <template slot-scope="scope" >
                        <upload-new></upload-new>
                    </template>
                </el-table-column>
                <el-table-column prop="" label="操作" >
                    <template slot-scope="scope" >
                        <el-button  icon="el-icon-delete" type="text"  @click="del(scope.row)" style="color:#909399">删除</el-button>
                    </template>
                </el-table-column>
            </el-table>
        </div>
        
        <div class="btn_area">
            <el-button size="small" type="success" round icon="el-icon-plus" @click="addFp">添加发票</el-button>
        </div>
        <div class="submit_area">
            <el-button size="small" type="primary">保存</el-button>
            <el-button size="small" @click="cancle">取消</el-button>
        </div>

    </div>
</template>

<script>

export default {
    components: { },
    props: {},
    data(){
        return{
            tableData:[{id:1}],
        }
    },
    computed: {
        rowguid:function(){
            return this.getQuery('rowguid')
        }  
    },
    watch:{
        
    },
    methods: {
        cancle: function(){
			this.$emit('close');
		},
        getDetail:function(){
            this.$get(this.$store.getters.partnerUrl + '/partner/'+this.dwcode, {}, function(data) {
                this.dwinfo = data.dwinfo;
                this.dwrateList = data.dwrateList;
                if(data.user){
                    this.user = data.user;
                }
            })
        },
        //上传
        upload:function(){

        },
        del:function(row){
            this.tableData.splice(row,1)
        },
        addFp:function(){
            this.tableData.push({id:1})
        },
      
    },
    mounted:function(){
          
    }
}
</script>

<style scoped lang="scss">

.main_con{
    
}

.table_aera{
    ::v-deep .el-table th > .cell {
        text-align: center;
    }
    ::v-deep .el-table .cell {
        text-align: center;
    }   
}
.btn_area{
    text-align: center;
    margin: 20px auto;

}
.submit_area{
    text-align: center;
}

</style>

